home *** CD-ROM | disk | FTP | other *** search
/ FM Towns: Free Software Collection 8 / FM Towns Free Software Collection 8.iso / t_os / artemis / artsrc1 / pict.c < prev    next >
C/C++ Source or Header  |  1994-06-01  |  28KB  |  810 lines

  1. /*
  2.     ARTemis (Graphic Editor for FM-TOWNS)
  3.     (c) MATSUUCHI Ryosuke 1992,1993
  4.  
  5.     pict.c
  6. */
  7.  
  8. #include <stdio.h>
  9. #include <egb.h>
  10. #include <msdos.cf>
  11.  
  12. #include "ge.h"
  13.  
  14. static char pic_nonum[] =
  15.     { 0xfe, 5,6, COL_menu, 0xfc,0xfc,0xfc,0xfc,0xfc,0xfc, 0xff };
  16.  
  17. static char pic_zero[] =
  18.     { 0xfe, 5,6, COL_menuString, 0xf8,0x98,0x98,0x98,0x98,0xf8, 0xff };
  19.  
  20. static char pic_one[] =
  21.     { 0xfe, 5,6, COL_menuString, 0x70,0x30,0x30,0x30,0x30,0x78, 0xff };
  22.  
  23. static char pic_two[] =
  24.     { 0xfe, 5,6, COL_menuString, 0xf8,0x18,0x18,0xf8,0x80,0xf8, 0xff };
  25.  
  26. static char pic_three[] =
  27.     { 0xfe, 5,6, COL_menuString, 0xf8,0x18,0xf8,0x18,0x18,0xf8, 0xff };
  28.  
  29. static char pic_four[] =
  30.     { 0xfe, 5,6, COL_menuString, 0xd0,0xd0,0xd0,0xf8,0x10,0x10, 0xff };
  31.  
  32. static char pic_five[] =
  33.     { 0xfe, 5,6, COL_menuString, 0xf8,0xc0,0xf8,0x08,0x08,0xf8, 0xff };
  34.  
  35. static char pic_six[] =
  36.     { 0xfe, 5,6, COL_menuString, 0xf8,0xc0,0xf8,0xc8,0xc8,0xf8, 0xff };
  37.  
  38. static char pic_seven[] =
  39.     { 0xfe, 5,6, COL_menuString, 0xf8,0x98,0x18,0x18,0x30,0x30, 0xff };
  40.  
  41. static char pic_eight[] =
  42.     { 0xfe, 5,6, COL_menuString, 0xf8,0x98,0xf8,0x98,0x98,0xf8, 0xff };
  43.  
  44. static char pic_nine[] =
  45.     { 0xfe, 5,6, COL_menuString, 0xf8,0x98,0x98,0xf8,0x18,0xf8, 0xff };
  46.  
  47. static char pic_rgb_r[] = {
  48.     0xfe, 11,9, COL_menuString,
  49.     0x3f,0x00,0x30,0x80,0x30,0x80,0x30,0x80,0x3f,0x00,0x32,
  50.     0x00,0x33,0x00,0x31,0x00,0x31,0x80,0xff
  51. };
  52.  
  53. static char pic_rgb_g[] = {
  54.     0xfe, 11,9, COL_menuString,
  55.     0x1f,0x00,0x30,0x80,0x30,0x00,0x30,0x00,0x33,0x80,0x30,
  56.     0x80,0x30,0x80,0x30,0x80,0x1f,0x80,0xff
  57. };
  58.  
  59. static char pic_rgb_b[] = {
  60.     0xfe, 11,9, COL_menuString,
  61.     0x3f,0x00,0x30,0x80,0x30,0x80,0x30,0x80,0x3f,0x00,0x30,
  62.     0x80,0x30,0x80,0x30,0x80,0x3f,0x00,0xff
  63. };
  64.  
  65.  
  66. static int    pic_rgb_updown[] = {
  67.     1,
  68.     15,White,
  69.     (int)"fffffffffff",
  70.     (int)"fffff1fffff",
  71.     (int)"ffff111ffff",
  72.     (int)"fff11111fff",
  73.     (int)"fffffffffff",
  74.     (int)"fffffffffff",
  75.     (int)"fffffffffff",
  76.     (int)"fffffffffff",
  77.     (int)"fffffffffff",
  78.     (int)"fffffffffff",
  79.     (int)"fff11111fff",
  80.     (int)"ffff111ffff",
  81.     (int)"fffff1fffff",
  82.     (int)"fffffffffff",
  83.     (int)NULL
  84.     };
  85.  
  86.  
  87. static char pic_save[] = {
  88.     0xfe, 20,20, Black,
  89.     0x00,0x00,0x00,0x00,0x00,0x00,0x3f,0xff,0x00,0x3e,0x19,0x80,
  90.     0x3e,0x19,0xc0,0x3e,0x19,0xc0,0x3e,0x01,0xc0,0x3f,0xff,0xc0,
  91.     0x3f,0xff,0xc0,0x30,0x00,0x80,0x30,0x00,0x60,0x30,0x01,0xe0,
  92.     0x30,0x07,0xe0,0x30,0x1f,0xe0,0x30,0x07,0xe0,0x30,0x01,0xe0,
  93.     0x30,0x00,0x60,0x3f,0xff,0x80,0x00,0x00,0x00,0x00,0x00,0x00,
  94.     0xff
  95. };
  96.  
  97. static char pic_load[] = {
  98.     0xfe, 20,20, Black,
  99.     0x00,0x00,0x00,0x00,0x00,0x00,0x3f,0xff,0x00,0x3e,0x19,0x80,
  100.     0x3e,0x19,0xc0,0x3e,0x19,0xc0,0x3e,0x01,0xc0,0x3f,0xff,0xc0,
  101.     0x3f,0xff,0xc0,0x30,0x00,0xc0,0x30,0x18,0xc0,0x30,0x1e,0x40,
  102.     0x30,0x1f,0x80,0x30,0x1f,0xe0,0x30,0x1f,0x80,0x30,0x1e,0x40,
  103.     0x30,0x18,0xc0,0x3f,0xe7,0xc0,0x00,0x00,0x00,0x00,0x00,0x00,
  104.     0xff
  105. };
  106.  
  107. static char pic_copy[] = {
  108.     0xfe, 20,20, Black,
  109.     0x00,0x00,0x00,0x00,0x00,0x00,0x3f,0xf0,0x00,0x20,0x10,0x00,
  110.     0x20,0x10,0x00,0x22,0xff,0xc0,0x27,0x00,0x40,0x23,0x80,0x40,
  111.     0x21,0xd0,0x40,0x20,0xf0,0x40,0x20,0x70,0x40,0x20,0xf0,0x40,
  112.     0x20,0x00,0x40,0x20,0x80,0x40,0x3f,0x80,0x40,0x00,0x80,0x40,
  113.     0x00,0x80,0x40,0x00,0x80,0x40,0x00,0xff,0xc0,0x00,0x00,0x00,
  114.     0xff
  115. };
  116.  
  117. static char pic_view[] = {
  118.     0xfe, 20,20, Black,
  119.     0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,
  120.     0x00,0x00,0x00,0x00,0x00,0x00,0x03,0xfc,0x00,0x0f,0xff,0x00,
  121.     0x1b,0xfd,0x80,0x27,0xfe,0x40,0x47,0xfe,0x20,0x03,0xfc,0x00,
  122.     0x11,0xf8,0x80,0x0f,0xff,0x00,0x00,0x00,0x00,0x00,0x00,0x00,
  123.     0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,
  124.     0xff
  125. };
  126.  
  127. static char pic_setup[] = {
  128.     0xfe, 20,20, Black,
  129.     0x00,0x00,0x00,0x37,0x80,0x00,0x14,0x80,0x00,0x04,0x80,0x00,
  130.     0x78,0xe0,0x00,0x00,0x00,0x00,0x37,0x80,0x00,0x00,0x83,0x00,
  131.     0x34,0x81,0x00,0x03,0x3f,0xe0,0x71,0x20,0x20,0x53,0x8f,0x80,
  132.     0x74,0xc2,0x00,0x00,0x0b,0x80,0x00,0x12,0x00,0x00,0x1e,0x00,
  133.     0x00,0x13,0x80,0x00,0x30,0xe0,0x00,0x00,0x00,0x00,0x00,0x00,
  134.     0xff
  135. };
  136.  
  137. static char pic_paint[] = {
  138.     0xfe, 20,20, Black,
  139.     0x00,0x00,0x00,0x00,0xc0,0x00,0x01,0x48,0x00,0x01,0x38,0x00,
  140.     0x01,0x24,0x00,0x01,0x42,0x00,0x00,0x81,0x00,0x01,0x80,0x80,
  141.     0x06,0xc0,0x40,0x0c,0x00,0x20,0x0b,0x00,0x20,0x08,0x80,0x40,
  142.     0x00,0x40,0x80,0x08,0x21,0x00,0x00,0x12,0x00,0x08,0x0c,0x00,
  143.     0x08,0x00,0x00,0x3f,0xe0,0x00,0x7f,0xfc,0x00,0x07,0x80,0x00,
  144.     0xff
  145. };
  146.  
  147. static char pic_line[] = {
  148.     0xfe, 20,20, Black,
  149.     0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x80,
  150.     0x00,0x01,0x00,0x00,0x02,0x00,0x00,0x04,0x00,0x00,0x08,0x00,
  151.     0x00,0x10,0x00,0x00,0x20,0x00,0x00,0x40,0x00,0x00,0x80,0x00,
  152.     0x01,0x00,0x00,0x02,0x00,0x00,0x04,0x00,0x00,0x08,0x00,0x00,
  153.     0x10,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,
  154.     0xff
  155. };
  156.  
  157. static char pic_spray[] = {
  158.     0xfe, 20,20, Black,
  159.     0x20,0x00,0x00,0x08,0x00,0x00,0x22,0x00,0x00,0x08,0xbf,0x00,
  160.     0x22,0x11,0x00,0x08,0xa1,0x00,0x22,0x3f,0x00,0x08,0x0c,0x00,
  161.     0x20,0x1e,0x00,0x00,0x21,0x00,0x00,0x40,0x80,0x00,0xff,0xc0,
  162.     0x00,0xff,0xc0,0x00,0xff,0xc0,0x00,0xff,0xc0,0x00,0xff,0xc0,
  163.     0x00,0x80,0x40,0x00,0x80,0x40,0x00,0xff,0xc0,0x00,0x00,0x00,
  164.     0xff
  165. };
  166.  
  167. static char pic_fline[] = {
  168.     0xfe, 20,20, Black,
  169.     0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x01,0xc0,
  170.     0x00,0x06,0x00,0x00,0x18,0x00,0x00,0x20,0x00,0x00,0x60,0x00,
  171.     0x01,0xf0,0x00,0x02,0x88,0x00,0x04,0x88,0x00,0x08,0x88,0x00,
  172.     0x08,0x88,0x00,0x10,0xf0,0x00,0x10,0x00,0x00,0x10,0x00,0x00,
  173.     0x10,0x00,0x00,0x08,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,
  174.     0xff
  175. };
  176.  
  177. static char pic_exit[] = {
  178.     0xfe, 20,20, Black,
  179.     0x00,0x00,0x00,0x07,0xfc,0x00,0x04,0x04,0x00,0x04,0x04,0x00,
  180.     0x04,0x04,0x00,0x04,0x04,0x00,0x04,0x04,0x00,0x05,0x84,0x00,
  181.     0x05,0x84,0x00,0x04,0x04,0x00,0x04,0x04,0x00,0x04,0x04,0x00,
  182.     0x04,0x04,0x00,0x07,0xfc,0x00,0x00,0x00,0x00,0x1d,0x57,0x00,
  183.     0x11,0x52,0x00,0x18,0x92,0x00,0x11,0x52,0x00,0x1d,0x52,0x00,
  184.     0xff
  185. };
  186.  
  187. static char pic_pen[] = {
  188.     0xfe, 20,20, Black,
  189.     0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,
  190.     0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x40,0x00,0x01,0x50,0x00,
  191.     0x00,0xe0,0x00,0x03,0xf8,0x00,0x00,0xe0,0x00,0x01,0x50,0x00,
  192.     0x00,0x40,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,
  193.     0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,
  194.     0xff
  195. };
  196.  
  197. static char pic_box[] = {
  198.     0xfe, 20,20, Black,
  199.     0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,
  200.     0x3f,0xff,0xc0,0x20,0x00,0x40,0x20,0x00,0x40,0x20,0x00,0x40,
  201.     0x20,0x00,0x40,0x20,0x00,0x40,0x20,0x00,0x40,0x20,0x00,0x40,
  202.     0x20,0x00,0x40,0x20,0x00,0x40,0x20,0x00,0x40,0x3f,0xff,0xc0,
  203.     0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,
  204.     0xff
  205. };
  206.  
  207. static char pic_boxfill[] = {
  208.     0xfe, 20,20, Black,
  209.     0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,
  210.     0x3f,0xff,0xc0,0x2a,0xaa,0xc0,0x35,0x55,0x40,0x2a,0xaa,0xc0,
  211.     0x35,0x55,0x40,0x2a,0xaa,0xc0,0x35,0x55,0x40,0x2a,0xaa,0xc0,
  212.     0x35,0x55,0x40,0x2a,0xaa,0xc0,0x35,0x55,0x40,0x3f,0xff,0xc0,
  213.     0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,
  214.     0xff
  215. };
  216.  
  217. static char pic_fpset[] = {
  218.     0xfe, 20,20, Black,
  219.     0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x01,0x40,
  220.     0x00,0x04,0x00,0x00,0x10,0x00,0x00,0x00,0x00,0x00,0x40,0x00,
  221.     0x00,0xa0,0x00,0x02,0x08,0x00,0x00,0x80,0x00,0x08,0x08,0x00,
  222.     0x00,0x80,0x00,0x10,0x50,0x00,0x00,0x00,0x00,0x10,0x00,0x00,
  223.     0x00,0x00,0x00,0x08,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,
  224.     0xff
  225. };
  226.  
  227. static char pic_pat[] = {
  228.     0xfe, 20,20, Black,
  229.     0x00,0x00,0x00,0x03,0xfc,0x00,0x04,0x02,0x00,0x08,0x01,0x00,
  230.     0x0f,0xff,0x00,0x3c,0x03,0xc0,0x19,0x99,0x80,0x0b,0x9d,0x00,
  231.     0x0b,0x0d,0xe0,0x08,0x01,0x20,0x08,0x91,0x20,0x10,0x60,0x40,
  232.     0x20,0x00,0x80,0x48,0x00,0x00,0x48,0xee,0xe0,0x78,0xaa,0x40,
  233.     0x08,0xee,0x40,0x08,0x8a,0x40,0x08,0x8a,0x40,0x00,0x00,0x00,
  234.     0xff
  235. };
  236.  
  237. static char pic_accent[] = {
  238.     0xfe, 20,20, Black,
  239.     0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,
  240.     0x00,0x00,0x00,0x00,0x00,0x00,0x18,0x00,0x00,0x34,0x00,0x00,
  241.     0x34,0x73,0x80,0x62,0xc6,0x00,0x7e,0xc6,0x00,0x62,0x73,0x80,
  242.     0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,
  243.     0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,
  244.     0xff
  245. };
  246.  
  247. static char pic_zoom[] = {
  248.     0xfe, 20,20, Black,
  249.     0x00,0x00,0x00,0x3f,0xc0,0x00,0x20,0x52,0x00,0x20,0x40,0x40,
  250.     0x20,0xff,0xe0,0x20,0x80,0x20,0x20,0x80,0x20,0x20,0x80,0x20,
  251.     0x20,0x80,0x20,0x3f,0x80,0x20,0x00,0x80,0x20,0x10,0x80,0x20,
  252.     0x00,0x80,0x20,0x00,0x80,0x20,0x04,0x80,0x20,0x00,0x80,0x20,
  253.     0x00,0x80,0x20,0x01,0x80,0x20,0x00,0xff,0xe0,0x00,0x00,0x00,
  254.     0xff
  255. };
  256.  
  257. static char pic_undo[] = {
  258.     0xfe, 20,20, Black,
  259.     0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,
  260.     0x40,0x00,0x00,0x68,0x0c,0x00,0x68,0x0c,0x00,0x68,0x04,0x00,
  261.     0x6b,0x0c,0xc0,0x6a,0x9d,0xa0,0x6a,0xb5,0xa0,0x6a,0xb5,0xa0,
  262.     0x6a,0xb5,0xa0,0x7a,0xbd,0xe0,0x36,0x9c,0xc0,0x00,0x00,0x00,
  263.     0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,
  264.     0xff
  265. };
  266.  
  267. static char pic_blot[] = {
  268.     0xfe, 20,20, Black,
  269.     0x00,0x00,0x00,0x08,0x30,0x00,0x0c,0x24,0x00,0x04,0x7e,0x00,
  270.     0x00,0x41,0x00,0x00,0x82,0x00,0x31,0xa6,0x80,0x39,0xf7,0xc0,
  271.     0x08,0x18,0x00,0x00,0x7e,0x00,0x07,0xc3,0xc0,0x07,0x38,0xe0,
  272.     0x04,0x62,0x00,0x0c,0x1c,0x00,0x18,0xf1,0x00,0x18,0x0e,0x00,
  273.     0x10,0xf8,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,
  274.     0xff
  275. };
  276.  
  277. static char pic_diffuse[] = {
  278.     0xfe, 20,20, Black,
  279.     0x00,0x00,0x00,0x2c,0x41,0x80,0x3d,0xef,0xc0,0x24,0x31,0x00,
  280.     0x34,0x23,0x00,0x35,0xff,0xe0,0x15,0x80,0x60,0x1d,0xbe,0xc0,
  281.     0x14,0x00,0x00,0x15,0xff,0xe0,0x1c,0xc0,0x00,0x1c,0xb8,0xc0,
  282.     0x15,0xac,0x80,0x35,0x2b,0x00,0x25,0x6a,0x80,0x64,0x5a,0x80,
  283.     0x64,0x94,0xc0,0x4c,0x2c,0xc0,0x00,0x00,0x40,0x00,0x00,0x00,
  284.     0xff
  285. };
  286.  
  287. static char pic_sand[] = {
  288.     0xfe, 20,20, Black,
  289.     0x00,0x00,0x00,0x00,0x0c,0x00,0x00,0x0c,0x00,0x00,0x0c,0x00,
  290.     0x00,0x24,0x00,0x07,0x36,0x80,0x3e,0x66,0xc0,0x18,0xe6,0x60,
  291.     0x38,0x46,0x20,0x30,0x16,0x00,0x7f,0x0e,0x80,0xfb,0x05,0x00,
  292.     0x1b,0x03,0x00,0x1f,0x06,0x00,0x1c,0x0c,0x00,0x10,0x38,0x00,
  293.     0x00,0xf0,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,
  294.     0xff
  295. };
  296.  
  297. static char pic_poly[] = {
  298.     0xfe, 20,20, Black,
  299.     0x00,0x00,0x00,0x00,0x00,0x00,0x10,0x00,0x00,0x1e,0x00,0x00,
  300.     0x15,0xc0,0x00,0x1a,0xb8,0x00,0x15,0x57,0x80,0x1a,0xaa,0xc0,
  301.     0x15,0x55,0x40,0x1a,0xaa,0xc0,0x35,0x55,0x40,0x2a,0xaa,0xc0,
  302.     0x35,0x55,0x40,0x2a,0xaa,0xc0,0x35,0x55,0x40,0x2a,0xaa,0xc0,
  303.     0x35,0x55,0x40,0x7f,0xff,0xc0,0x00,0x00,0x00,0x00,0x00,0x00,
  304.     0xff
  305. };
  306.  
  307. static char pic_goshi[] = {
  308.     0xfe, 20,20, Black,
  309.     0x00,0x00,0x00,0x30,0x38,0x00,0x38,0x18,0x00,0x1b,0xff,0xc0,
  310.     0x1b,0x00,0xc0,0x7d,0x77,0x00,0x48,0xb5,0x00,0x09,0xf2,0x00,
  311.     0x08,0x6f,0x00,0x08,0xc1,0xe0,0x0d,0x1e,0x40,0x38,0x70,0x00,
  312.     0x79,0x03,0x80,0x49,0xff,0xc0,0x18,0x08,0x00,0x10,0xc9,0x00,
  313.     0x71,0x98,0xc0,0x72,0x18,0x40,0x20,0x38,0x00,0x00,0x00,0x00,
  314.     0xff
  315. };
  316.  
  317. static char pic_play[] = {
  318.     0xfe, 20,20, Black,
  319.     0x00,0x00,0x00,0x00,0x00,0x00,0x0f,0xff,0x00,0x08,0x01,0x00,
  320.     0x08,0x81,0x00,0x08,0xc1,0x00,0x08,0xe1,0x00,0x08,0xf1,0x00,
  321.     0x08,0xe1,0x00,0x08,0xc1,0x00,0x08,0x81,0x00,0x08,0x01,0x00,
  322.     0x0f,0xff,0x00,0x00,0x00,0x00,0x72,0x1a,0x20,0x4a,0x25,0x40,
  323.     0x7a,0x24,0x80,0x42,0x3c,0x80,0x43,0xa4,0x80,0x00,0x00,0x00,
  324.     0xff
  325. };
  326.  
  327. static char pic_rec[] = {
  328.     0xfe, 20,20, Black,
  329.     0x00,0x00,0x00,0x00,0x00,0x00,0x0f,0xff,0x00,0x08,0x01,0x00,
  330.     0x08,0x81,0x00,0x08,0xc1,0x00,0x08,0xe1,0x00,0x08,0xf1,0x00,
  331.     0x08,0xe1,0x00,0x08,0xc1,0x00,0x08,0x81,0x00,0x08,0x01,0x00,
  332.     0x0f,0xff,0x00,0x00,0x00,0x00,0x1e,0xf7,0x80,0x12,0x84,0x00,
  333.     0x1e,0xe4,0x00,0x14,0x84,0x00,0x12,0xf7,0x80,0x00,0x00,0x00,
  334.     0xff
  335. };
  336.  
  337. static char pic_stop[] = {
  338.     0xfe, 20,20, Black,
  339.     0x00,0x00,0x00,0x00,0x00,0x00,0x0f,0xff,0x00,0x08,0x01,0x00,
  340.     0x08,0x01,0x00,0x08,0x01,0x00,0x08,0x61,0x00,0x08,0x61,0x00,
  341.     0x08,0x61,0x00,0x08,0x01,0x00,0x08,0x01,0x00,0x08,0x01,0x00,
  342.     0x0f,0xff,0x00,0x00,0x00,0x00,0x3f,0xfd,0xe0,0x21,0x25,0x20,
  343.     0x3d,0x25,0xe0,0x05,0x25,0x00,0x3d,0x3d,0x00,0x00,0x00,0x00,
  344.     0xff
  345. };
  346.  
  347. static char pic_sand_area[] = {
  348.     0xfe, 20,20, Black,
  349.     0x00,0x00,0x00,0x01,0xe0,0x00,0x1e,0x20,0x00,0x10,0x20,0x00,
  350.     0x10,0x20,0x00,0x20,0x20,0x00,0x20,0x26,0x00,0x20,0x02,0x00,
  351.     0x20,0x0a,0x00,0x43,0xdb,0x40,0x41,0x13,0x60,0x43,0x02,0x20,
  352.     0x72,0x00,0x80,0x07,0xc1,0x00,0x01,0x43,0x00,0x01,0xc6,0x00,
  353.     0x01,0x0c,0x00,0x00,0x38,0x00,0x00,0x00,0x00,0x00,0x00,0x00,
  354.     0xff
  355. };
  356.  
  357. static char pic_diffuse_area[] = {
  358.     0xfe, 20,20, Black,
  359.     0x00,0x00,0x00,0x01,0xe0,0x00,0x1e,0x20,0x00,0x10,0x20,0x00,
  360.     0x10,0x20,0x00,0x20,0x00,0x00,0x20,0x08,0x80,0x23,0xbf,0xe0,
  361.     0x22,0x88,0x80,0x42,0xbf,0xe0,0x43,0xaf,0x20,0x42,0x80,0x00,
  362.     0x7a,0xbf,0xe0,0x03,0x9b,0x00,0x02,0xa5,0x20,0x02,0x9b,0xc0,
  363.     0x02,0xb5,0x80,0x02,0x89,0x60,0x00,0x03,0x20,0x00,0x00,0x00,
  364.     0xff
  365. };
  366.  
  367. static char pic_smooth[] = {
  368.     0xfe, 20,20, Black,
  369.     0x00,0x00,0x00,0x01,0xe0,0x00,0x1e,0x20,0x00,0x10,0x20,0x00,
  370.     0x10,0x20,0x00,0x20,0x00,0x40,0x20,0xcf,0xe0,0x20,0x4c,0x60,
  371.     0x20,0x05,0xc0,0x40,0x05,0x40,0x41,0xbf,0xe0,0x40,0x10,0x20,
  372.     0x7c,0x07,0xc0,0x00,0x24,0x40,0x00,0x27,0xc0,0x00,0x4c,0x40,
  373.     0x00,0xcf,0xc0,0x01,0x88,0xc0,0x00,0x08,0xc0,0x00,0x00,0x00,
  374.     0xff
  375. };
  376.  
  377. static char pic_copypoly[] = {
  378.     0xfe, 20,20, Black,
  379.     0x00,0x06,0x00,0x00,0x3a,0x00,0x01,0xc2,0x00,0x0e,0x02,0x00,
  380.     0x08,0x02,0x00,0x10,0x00,0x60,0x10,0x03,0xa0,0x10,0x9c,0x20,
  381.     0x21,0xc0,0x20,0x20,0xe0,0x20,0x21,0x74,0x20,0x41,0x3c,0x20,
  382.     0x7d,0x1c,0x20,0x02,0x3c,0x20,0x02,0x00,0x20,0x02,0x00,0x20,
  383.     0x04,0x00,0x20,0x07,0xff,0xe0,0x00,0x00,0x00,0x00,0x00,0x00,
  384.     0xff
  385. };
  386.  
  387. static char pic_rotatebox[] = {
  388.     0xfe, 20,20, Black,
  389.     0x00,0x00,0x00,0x7f,0xfe,0x00,0x40,0x02,0xc0,0x40,0x02,0x20,
  390.     0x41,0x02,0x60,0x41,0xc2,0x20,0x42,0x32,0x00,0x42,0x0c,0x00,
  391.     0x44,0x03,0x00,0x44,0x00,0xc0,0x68,0x00,0x20,0x08,0x00,0x40,
  392.     0x18,0x00,0x40,0x0c,0x00,0x80,0x03,0x00,0x80,0x00,0xc1,0x00,
  393.     0x00,0x31,0x00,0x00,0x0e,0x00,0x00,0x02,0x00,0x00,0x00,0x00,
  394.     0xff
  395. };
  396.  
  397. static char pic_rotatepoly[] = {
  398.     0xfe, 20,20, Black,
  399.     0x00,0x06,0x00,0x00,0x3a,0xc0,0x01,0xc2,0x20,0x0e,0x02,0x60,
  400.     0x08,0x02,0x20,0x10,0x00,0x00,0x10,0x7f,0xe0,0x10,0x40,0x20,
  401.     0x20,0x80,0x20,0x21,0x00,0x20,0x21,0x00,0x40,0x42,0x00,0x40,
  402.     0x74,0x00,0x40,0x04,0x00,0x80,0x08,0x00,0x80,0x0e,0x00,0x80,
  403.     0x01,0xc1,0x00,0x00,0x39,0x00,0x00,0x07,0x00,0x00,0x00,0x00,
  404.     0xff
  405. };
  406.  
  407. static char pic_zoompoly[] = {
  408.     0xfe, 20,20, Black,
  409.     0x00,0x00,0x00,0x00,0x20,0x00,0x01,0xe4,0x00,0x0e,0x20,0x80,
  410.     0x08,0x20,0x00,0x10,0x20,0x60,0x10,0x23,0xa0,0x10,0x1c,0x20,
  411.     0x3e,0xe0,0x20,0x00,0x80,0x20,0x21,0x00,0x20,0x01,0x00,0x20,
  412.     0x11,0x00,0x20,0x02,0x00,0x20,0x12,0x00,0x20,0x02,0x00,0x20,
  413.     0x04,0x00,0x20,0x07,0xff,0xe0,0x00,0x00,0x00,0x00,0x00,0x00,
  414.     0xff
  415. };
  416.  
  417. static char pic_colchg[] = {
  418.     0xfe, 20,20, Black,
  419.     0x00,0x00,0x00,0x00,0x00,0x00,0x1f,0x00,0x00,0x32,0x00,0x00,
  420.     0x64,0x00,0x00,0x7f,0x80,0x00,0x64,0x86,0x00,0x64,0x83,0x00,
  421.     0x7f,0xbf,0xe0,0x60,0x05,0x00,0x60,0x15,0x60,0x61,0xb5,0x20,
  422.     0x7f,0x80,0x00,0x00,0x0f,0x80,0x00,0x09,0x80,0x00,0x15,0x00,
  423.     0x00,0x03,0x80,0x00,0x3c,0xe0,0x00,0x00,0x00,0x00,0x00,0x00,
  424.     0xff
  425. };
  426.  
  427. static char pic_sharp[] = {
  428.     0xfe, 20,20, Black,
  429.     0x00,0x00,0x00,0x01,0xe0,0x00,0x1e,0x20,0x00,0x10,0x20,0x00,
  430.     0x10,0x20,0x00,0x20,0x20,0x00,0x20,0x00,0x00,0x20,0x3b,0xc0,
  431.     0x2f,0xa9,0xc0,0x45,0x69,0x80,0x46,0x5b,0x00,0x45,0x14,0xc0,
  432.     0x75,0xa0,0x60,0x07,0x4e,0x00,0x04,0x00,0x00,0x04,0x7f,0xc0,
  433.     0x04,0x04,0x00,0x04,0x24,0x80,0x04,0x6c,0xc0,0x00,0x00,0x00,
  434.     0xff
  435. };
  436.  
  437. static char pic_boxvturn[] = {
  438.     0xfe, 20,20, Black,
  439.     0x00,0x00,0x00,0x7f,0xf0,0x00,0x40,0x10,0x00,0x40,0x10,0x00,
  440.     0x47,0xff,0x00,0x44,0x01,0x00,0x44,0x01,0x00,0x44,0x01,0x00,
  441.     0x44,0x01,0x00,0x44,0x00,0x00,0x44,0x01,0x80,0x44,0x03,0xc0,
  442.     0x44,0x07,0xe0,0x7c,0x01,0x80,0x04,0x01,0x80,0x04,0x01,0x80,
  443.     0x07,0xf7,0xe0,0x00,0x03,0xc0,0x00,0x01,0x80,0x00,0x00,0x00,
  444.     0xff
  445. };
  446.  
  447. static char pic_boxhturn[] = {
  448.     0xfe, 20,20, Black,
  449.     0x00,0x00,0x00,0x7f,0xf0,0x00,0x40,0x10,0x00,0x40,0x10,0x00,
  450.     0x47,0xff,0x00,0x44,0x01,0x00,0x44,0x01,0x00,0x44,0x01,0x00,
  451.     0x44,0x01,0x00,0x44,0x01,0x00,0x44,0x01,0x00,0x44,0x01,0x00,
  452.     0x44,0x01,0x00,0x7c,0x08,0x80,0x04,0x18,0xc0,0x04,0x3f,0xe0,
  453.     0x07,0xbf,0xe0,0x00,0x18,0xc0,0x00,0x08,0x80,0x00,0x00,0x00,
  454.     0xff
  455. };
  456.  
  457. static char pic_polyvturn[] = {
  458.     0xfe, 20,20, Black,
  459.     0x00,0x00,0x00,0x00,0x3c,0x00,0x03,0xc4,0x00,0x0c,0x00,0x00,
  460.     0x08,0x07,0x80,0x08,0x78,0x80,0x11,0x80,0x80,0x11,0x00,0x80,
  461.     0x11,0x00,0x80,0x22,0x00,0x00,0x22,0x01,0x80,0x22,0x03,0xc0,
  462.     0x44,0x07,0xe0,0x74,0x01,0x80,0x04,0x01,0x80,0x08,0x01,0x80,
  463.     0x0f,0xf7,0xe0,0x00,0x03,0xc0,0x00,0x01,0x80,0x00,0x00,0x00,
  464.     0xff
  465. };
  466.  
  467. static char pic_polyhturn[] = {
  468.     0xfe, 20,20, Black,
  469.     0x00,0x00,0x00,0x00,0x3c,0x00,0x03,0xc4,0x00,0x0c,0x00,0x00,
  470.     0x08,0x07,0x80,0x08,0x78,0x80,0x11,0x80,0x80,0x11,0x00,0x80,
  471.     0x11,0x00,0x80,0x22,0x00,0x80,0x22,0x00,0x80,0x22,0x00,0x80,
  472.     0x44,0x00,0x00,0x74,0x08,0x80,0x04,0x18,0xc0,0x08,0x3f,0xe0,
  473.     0x0f,0xbf,0xe0,0x00,0x18,0xc0,0x00,0x08,0x80,0x00,0x00,0x00,
  474.     0xff
  475. };
  476.  
  477. static char pic_penbase[] = {
  478.     0xfe,
  479.     20,26, Black,
  480.     0xff,0xff,0xf0, 0x80,0x00,0x10, 0x80,0x00,0x10, 0x80,0x00,0x10,
  481.     0x80,0x00,0x10, 0x80,0x00,0x10, 0x80,0x00,0x10, 0x80,0x00,0x10,
  482.     0x80,0x00,0x10, 0x80,0x00,0x10, 0x80,0x00,0x10, 0x80,0x00,0x10,
  483.     0x80,0x00,0x10, 0x80,0x00,0x10, 0x80,0x00,0x10, 0x80,0x00,0x10,
  484.     0x80,0x00,0x10, 0x80,0x00,0x10, 0x80,0x00,0x10, 0xff,0xff,0xf0,
  485.     0x00,0x00,0x00, 0x1e,0xf4,0x80, 0x12,0x86,0x80, 0x1e,0xe5,0x80,
  486.     0x10,0x84,0x80, 0x10,0xf4,0x80,
  487.     20,26, White,
  488.     0x00,0x00,0x00, 0x7f,0xff,0xe0, 0x7f,0xff,0xe0, 0x7f,0xff,0xe0, 
  489.     0x7f,0xff,0xe0, 0x7f,0xff,0xe0, 0x7f,0xff,0xe0, 0x7f,0xff,0xe0, 
  490.     0x7f,0xff,0xe0, 0x7f,0xff,0xe0, 0x7f,0xff,0xe0, 0x7f,0xff,0xe0, 
  491.     0x7f,0xff,0xe0, 0x7f,0xff,0xe0, 0x7f,0xff,0xe0, 0x7f,0xff,0xe0, 
  492.     0x7f,0xff,0xe0, 0x7f,0xff,0xe0, 0x7f,0xff,0xe0, 0x00,0x00,0x00,
  493.     0x00,0x00,0x00, 0x00,0x00,0x00, 0x00,0x00,0x00, 0x00,0x00,0x00,
  494.     0x00,0x00,0x00, 0x00,0x00,0x00,
  495.     0xff
  496. };
  497.  
  498. static int    pic_bikkuri[] = {
  499.     3,
  500.     1,Black,
  501.     15,Yellow,
  502.     2,Black,
  503.     (int)"00000000000000000000",
  504.     (int)"00000002222220000000",
  505.     (int)"00000222111122200000",
  506.     (int)"000022111ff111220000",
  507.     (int)"00022111ffff11122000",
  508.     (int)"0022111ffffff1112200",
  509.     (int)"0021111ffffff1111200",
  510.     (int)"0221111ffffff1111220",
  511.     (int)"02111111ffff11111120",
  512.     (int)"02111111ffff11111120",
  513.     (int)"02111111ffff11111120",
  514.     (int)"021111111ff111111120",
  515.     (int)"022111111ff111111220",
  516.     (int)"00211111111111111200",
  517.     (int)"00221111111111112200",
  518.     (int)"000221111ff111122000",
  519.     (int)"000022111ff111220000",
  520.     (int)"00000222111122200000",
  521.     (int)"00000002222220000000",
  522.     (int)"00000000000000000000",
  523.     (int)NULL
  524.     };
  525.  
  526. static char pic_rgb_updown2[] = {
  527.     0xfe,
  528.     11,14, COL_menuLight,
  529.     0xff,0xe0,0x80,0x00,0x82,0x00,0x81,0x00,0x80,0x80,0x8f,0x80,0x80,0x00,
  530.     0xff,0xe0,0x80,0x00,0x80,0x80,0x81,0x00,0x82,0x00,0x80,0x00,0x80,0x00,
  531.     11,14, COL_menuShade,
  532.     0x00,0x00,0x00,0x20,0x04,0x20,0x0e,0x20,0x1f,0x20,0x00,0x20,0x7f,0xe0,
  533.     0x00,0x00,0x00,0x20,0x1f,0x20,0x0e,0x20,0x04,0x20,0x00,0x20,0x7f,0xe0,
  534.     0xff
  535. };
  536.  
  537. static char pic_artemis[] = {
  538.     0xfe,
  539.     52,12, 0xff,
  540.     0x0c,0x3f,0x3f,0xf0,0x00,0x00,0x00,
  541.     0x0c,0x30,0x83,0x00,0x00,0x00,0x00,
  542.     0x0c,0x30,0x43,0x00,0x00,0x18,0x00,
  543.     0x16,0x30,0x43,0x00,0x00,0x18,0x00,
  544.     0x16,0x30,0x43,0x00,0x00,0x00,0x00,
  545.     0x16,0x30,0x83,0x0e,0x3d,0x99,0xf0,
  546.     0x23,0x3f,0x03,0x19,0x32,0x5b,0x00,
  547.     0x23,0x32,0x03,0x30,0xb2,0x5b,0x00,
  548.     0x23,0x31,0x03,0x3f,0xb2,0x59,0xe0,
  549.     0x7f,0xb1,0x03,0x30,0x32,0x58,0x30,
  550.     0x41,0xb0,0x83,0x18,0x32,0x58,0x30,
  551.     0x41,0xb0,0xc3,0x0f,0x32,0x5b,0xe0,
  552.     0xff
  553. };
  554.  
  555. static char pic_selectoff[] = {
  556.     0xfe,
  557.     12,12, COL_menu,
  558.     0xff,0xf0,0xff,0xf0,0xff,0xf0,0xff,0xf0,0xff,0xf0,0xff,0xf0,
  559.     0xff,0xf0,0xff,0xf0,0xff,0xf0,0xff,0xf0,0xff,0xf0,0xff,0xf0,
  560.     12,12, COL_menuString,
  561.     0x00,0x00,0x3f,0xc0,0x40,0x20,0x40,0x20,0x40,0x20,0x40,0x20,
  562.     0x40,0x20,0x40,0x20,0x40,0x20,0x40,0x20,0x3f,0xc0,0x00,0x00,
  563.     0xff
  564. };
  565.  
  566. static char pic_selecton[] = {
  567.     0xfe,
  568.     12,12, COL_menuString,
  569.     0x00,0x00,0x3f,0xc0,0x40,0x20,0x40,0x20,0x40,0x20,0x40,0x20,
  570.     0x40,0x20,0x40,0x20,0x40,0x20,0x40,0x20,0x3f,0xc0,0x00,0x00,
  571.     12,12, Black,
  572.     0x00,0x20,0x00,0x40,0x00,0x80,0x01,0x00,0x03,0x00,0x16,0x00,
  573.     0x0e,0x00,0x0c,0x00,0x04,0x00,0x00,0x00,0x00,0x00,0x00,0x00,
  574.     0xff
  575. };
  576.  
  577.  
  578. static char pic_leftsw[] = {
  579.     0xfe,
  580.     12,12, COL_menu,
  581.     0x00,0x00,0x7f,0xe0,0x7c,0xe0,0x78,0x60,0x70,0x60,0x60,0x60,
  582.     0x60,0x60,0x70,0x60,0x78,0x60,0x7c,0x60,0x7f,0xe0,0x00,0x00,
  583.     12,12, COL_menu2,
  584.     0x00,0x00,0x00,0x00,0x00,0x00,0x03,0x00,0x07,0x00,0x0f,0x00,
  585.     0x1f,0x00,0x0f,0x00,0x07,0x00,0x00,0x00,0x00,0x00,0x00,0x00,
  586.     12,12, COL_menuLight,
  587.     0xff,0xf0,0x80,0x00,0x80,0x00,0x80,0x80,0x80,0x80,0x80,0x80,
  588.     0x80,0x80,0x80,0x80,0x80,0x80,0x83,0x80,0x80,0x00,0x80,0x00,
  589.     12,12, COL_menuShade,
  590.     0x00,0x00,0x00,0x10,0x03,0x10,0x04,0x10,0x08,0x10,0x10,0x10,
  591.     0x00,0x10,0x00,0x10,0x00,0x10,0x00,0x10,0x00,0x10,0x7f,0xf0,
  592.     0xff
  593. };
  594.  
  595. static char pic_rightsw[] = {
  596.     0xfe,
  597.     12,12, COL_menu,
  598.     0x00,0x00,0x7f,0xe0,0x67,0xe0,0x63,0xe0,0x61,0xe0,0x60,0xe0,
  599.     0x60,0x60,0x60,0xe0,0x61,0xe0,0x63,0xe0,0x7f,0xe0,0x00,0x00,
  600.     12,12, COL_menu2,
  601.     0x00,0x00,0x00,0x00,0x00,0x00,0x0c,0x00,0x0e,0x00,0x0f,0x00,
  602.     0x0f,0x00,0x0e,0x00,0x0c,0x00,0x00,0x00,0x00,0x00,0x00,0x00,
  603.     12,12, COL_menuLight,
  604.     0xff,0xf0,0x80,0x00,0x80,0x00,0x80,0x00,0x80,0x00,0x80,0x00,
  605.     0x80,0x80,0x81,0x00,0x82,0x00,0x9c,0x00,0x80,0x00,0x80,0x00,
  606.     12,12, COL_menuShade,
  607.     0x00,0x00,0x00,0x10,0x18,0x10,0x10,0x10,0x10,0x10,0x10,0x10,
  608.     0x10,0x10,0x10,0x10,0x10,0x10,0x00,0x10,0x00,0x10,0x7f,0xf0,
  609.     0xff
  610. };
  611.  
  612. static char pic_upsw[] = {
  613.     0xfe,
  614.     12,12, COL_menu,
  615.     0x00,0x00,0x7f,0xe0,0x7f,0xe0,0x7b,0xe0,0x71,0xe0,0x60,0xe0,
  616.     0x40,0x60,0x40,0x20,0x60,0x20,0x7f,0xe0,0x7f,0xe0,0x00,0x00,
  617.     12,12, COL_menu2,
  618.     0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x06,0x00,0x0f,0x00,
  619.     0x1f,0x80,0x1f,0x80,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,
  620.     12,12, COL_menuLight,
  621.     0xff,0xf0,0x80,0x00,0x80,0x00,0x80,0x00,0x80,0x00,0x80,0x00,
  622.     0x80,0x00,0x80,0x40,0x9f,0xc0,0x80,0x00,0x80,0x00,0x80,0x00,
  623.     12,12, COL_menuShade,
  624.     0x00,0x00,0x00,0x10,0x00,0x10,0x04,0x10,0x08,0x10,0x10,0x10,
  625.     0x20,0x10,0x20,0x10,0x00,0x10,0x00,0x10,0x00,0x10,0x7f,0xf0,
  626.     0xff
  627. };
  628.  
  629. static char pic_downsw[] = {
  630.     0xfe,
  631.     12,12, COL_menu,
  632.     0x00,0x00,0x7f,0xe0,0x7f,0xe0,0x40,0x60,0x40,0x20,0x40,0x20,
  633.     0x70,0x60,0x78,0xe0,0x79,0xe0,0x7f,0xe0,0x7f,0xe0,0x00,0x00,
  634.     12,12, COL_menu2,
  635.     0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x1f,0x80,0x1f,0x80,
  636.     0x0f,0x00,0x06,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,
  637.     12,12, COL_menuLight,
  638.     0xff,0xf0,0x80,0x00,0x80,0x00,0x80,0x00,0x80,0x40,0x80,0x40,
  639.     0x80,0x80,0x81,0x00,0x86,0x00,0x80,0x00,0x80,0x00,0x80,0x00,
  640.     12,12, COL_menuShade,
  641.     0x00,0x00,0x00,0x10,0x00,0x10,0x3f,0x90,0x20,0x10,0x20,0x10,
  642.     0x00,0x10,0x00,0x10,0x00,0x10,0x00,0x10,0x00,0x10,0x7f,0xf0,
  643.     0xff
  644. };
  645.  
  646. static char pic_mask[] = {
  647.     0xfe,
  648.     20,20, Black,
  649.     0x00,0x00,0x00,0x1c,0x03,0x80,0x13,0x0c,0x80,0x10,0xf0,0x80,
  650.     0x10,0x00,0x80,0x0b,0x0d,0x00,0x0b,0x9d,0x00,0x08,0x91,0x00,
  651.     0x04,0x02,0x00,0x04,0x62,0x00,0x02,0x94,0x00,0x01,0x08,0x00,
  652.     0x00,0x00,0x00,0x7e,0xf9,0xe0,0x06,0x19,0x20,0x04,0x13,0x20,
  653.     0x34,0x20,0x60,0x18,0x70,0x60,0x0c,0xd8,0xc0,0x00,0x00,0x00,
  654.     0xff
  655. };
  656.  
  657. static char pic_test[] = {
  658.     0xfe,
  659.     20,20, Black,
  660.     0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x01,0x00,
  661.     0x3c,0x01,0x00,0x00,0xfd,0x00,0x7e,0x09,0x00,0x08,0x11,0x80,
  662.     0x08,0x31,0x60,0x18,0x49,0x00,0x10,0x85,0x00,0x20,0x01,0x00,
  663.     0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,
  664.     0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,
  665.     0xff
  666. };
  667.  
  668. static char pic_ellipsefill[] = {
  669.     0xfe,
  670.     20,20, Black,
  671.     0x00,0x00,0x00,0x00,0x00,0x00,0x01,0xf8,0x00,0x0f,0x57,0x00,
  672.     0x1a,0xaa,0x80,0x35,0x55,0x40,0x2a,0xaa,0xc0,0x55,0x55,0x60,
  673.     0x6a,0xaa,0xa0,0x55,0x55,0x60,0x6a,0xaa,0xa0,0x55,0x55,0x60,
  674.     0x2a,0xaa,0xc0,0x35,0x55,0x40,0x1a,0xaa,0x80,0x0f,0x57,0x00,
  675.     0x01,0xf8,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,
  676.     0xff
  677. };
  678.  
  679. static char pic_ellipse[] = {
  680.     0xfe,
  681.     20,20, Black,
  682.     0x00,0x00,0x00,0x00,0x00,0x00,0x01,0xf8,0x00,0x0e,0x07,0x00,
  683.     0x10,0x00,0x80,0x20,0x00,0x40,0x20,0x00,0x40,0x40,0x00,0x20,
  684.     0x40,0x00,0x20,0x40,0x00,0x20,0x40,0x00,0x20,0x40,0x00,0x20,
  685.     0x40,0x00,0x20,0x20,0x00,0x40,0x20,0x00,0x40,0x10,0x00,0x80,
  686.     0x0e,0x07,0x00,0x01,0xf8,0x00,0x00,0x00,0x00,0x00,0x00,0x00,
  687.     0xff
  688. };
  689.  
  690. static char pic_airbrush[] = {
  691.     0xfe,
  692.     20,20, Black,
  693.     0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x40,0x00,0x00,
  694.     0x10,0x00,0x00,0x45,0xf8,0x00,0x11,0xc6,0x00,0x40,0x81,0x00,
  695.     0x01,0xc0,0x80,0x03,0xe0,0x80,0x04,0x10,0x40,0x04,0x10,0x40,
  696.     0x04,0x10,0x40,0x04,0x10,0x40,0x04,0x10,0x00,0x07,0xf0,0x00,
  697.     0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,
  698.     0xff
  699. };
  700.  
  701. static char *piclist[] =
  702. {
  703.     NULL,
  704.     (char*)pic_nonum,
  705.     (char*)pic_zero,(char*)pic_one,(char*)pic_two,(char*)pic_three,
  706.     (char*)pic_four,(char*)pic_five,(char*)pic_six,(char*)pic_seven,
  707.     (char*)pic_eight,(char*)pic_nine,
  708.     (char*)pic_rgb_updown,
  709.     (char*)pic_rgb_r,(char*)pic_rgb_g,(char*)pic_rgb_b,
  710.     (char*)pic_save,(char*)pic_load,(char*)pic_copy,(char*)pic_view,
  711.     (char*)pic_leftsw,(char*)pic_rightsw,
  712.     (char*)pic_setup,(char*)pic_paint,(char*)pic_line,(char*)pic_spray,
  713.     (char*)pic_fline,(char*)pic_exit,(char*)pic_pen,
  714.     pic_boxfill,(char*)pic_penbase,(char*)pic_fpset,
  715.     (char*)pic_pat,(char*)pic_accent,(char*)pic_zoom,
  716.     (char*)pic_bikkuri,(char*)pic_undo,
  717.     (char*)pic_blot,(char*)pic_diffuse,(char*)pic_sand,
  718.     (char*)pic_poly,(char*)pic_goshi,
  719.     (char*)pic_play,(char*)pic_rec,(char*)pic_stop,
  720.     (char*)pic_sand_area,(char*)pic_diffuse_area,(char*)pic_smooth,
  721.     (char*)pic_copypoly,(char*)pic_rotatebox,
  722.     (char*)pic_rotatepoly,(char*)pic_zoompoly,
  723.     (char*)pic_colchg,(char*)pic_sharp,
  724.     (char*)pic_boxvturn, (char*)pic_boxhturn,
  725.     (char*)pic_polyvturn,(char*)pic_polyhturn,
  726.     (char*)pic_rgb_updown2,
  727.     (char*)pic_artemis,pic_selectoff,pic_selecton,
  728.     pic_upsw, pic_downsw,
  729.     pic_mask, pic_test,
  730.     pic_ellipse, pic_ellipsefill, pic_box,
  731.     pic_airbrush,
  732.     NULL
  733. };
  734.  
  735.  
  736. void putpict(int x, int y, int num)
  737. {
  738.     char *p;  char *sp;  int i,c,xx,yy;
  739.     int plt[16];
  740.     for (i=0; i<16; i++)
  741.         plt[i] = i;
  742.     p = piclist[num];
  743.     if (p == NULL)
  744.         return;
  745.     if (*p == 0xff)
  746.     {
  747.         static char bit[] = {128,64,32,16,8,4,2,1};
  748.         int xlen,ylen,xbytes,i,j,k;
  749.         xlen = *(p+1), ylen = *(p+2),  p+=3;
  750.         xbytes = (xlen+7)/8;
  751.         if (DMgetifonepage())
  752.         {
  753.             char patbuf[32*32*2];
  754.             pict_makeicon32k(patbuf,xlen,ylen,p);
  755.             grp_putblk(x,y,xlen,ylen, (char*)patbuf, DrawNORMAL);
  756.         }
  757.         else
  758.         {
  759.             char patbuf[32*32*2];
  760.             pict_makeicon16(patbuf,xlen,ylen,p);
  761.             grp_putblk(x,y,xlen,ylen, (char*)patbuf, DrawNORMAL);
  762.             // for (i=0; i<ylen; i++,p+=xbytes)
  763.             // {
  764.             //     for (j=0; j<xbytes; j++)
  765.             //         for (k=0; k<8; k++)
  766.             //             if (j*8+k < xlen && (*(p + j) & bit[k]) != 0)
  767.             //                 gpset(x+j*8+k,y+i,Black,DrawNORMAL);
  768.             // }
  769.         }
  770.     }
  771.     else if (*p == 0xfe)
  772.     {
  773.         p++;
  774.         while (*p != 0xff)
  775.         {
  776.             int xlen=*p,ylen=*(p+1),plt=*(p+2);
  777.             p+=3;
  778.  
  779.             #define    PUTBITBLOCK(x1,y1,x2,y2,dat) { \
  780.                 char para[16];   DWORD(para)=(unsigned int)dat; WORD(para+4)=getds(); \
  781.                 WORD(para+6)=x1; WORD(para+8)=y1; WORD(para+10)=x2; WORD(para+12)=y2; \
  782.                 EGB_putBlockColor(EGB_work, 0, para); }
  783.             if (plt != 0xff)
  784.                 EGB_color(EGB_work, 0, DMgetmenuplt(plt));
  785.             EGB_writeMode(EGB_work, DrawNORMAL);
  786.             PUTBITBLOCK(x,y,x+xlen-1,y+ylen-1, p);
  787.  
  788.             p += ((xlen+7)/8)*ylen;
  789.         }
  790.     }
  791.     else
  792.     {
  793.         int *pp = (int*)p;
  794.         for (i=*pp,pp++; i; i--,pp+=2)
  795.             plt[*pp] = *(pp+1);
  796.         for (yy=0; *pp!=(int)NULL; pp++,yy++)
  797.         {
  798.             for (sp=(char*)*pp,xx=0; *sp!=0; sp++,xx++)
  799.             {
  800.                 c = plt[ctox(*sp)];
  801.                 if (c != 0)
  802.                     gpset(x+xx,y+yy,menu_plt(c),DrawNORMAL);
  803.             }
  804.         }
  805.     }
  806. }
  807.  
  808.  
  809. /* end of pict.c */
  810.